package cn.agiledata.bank.common.bean;

public class LabelIntEnum extends IntEnum {
    private String label;

    public LabelIntEnum(int value, String label) {
        super(value);
        this.label = label;
    }

    public final String getLabel() {
        return this.label;
    }

    public boolean equals(Object object) {
        if (object == null || !(object instanceof IntEnum))
            return false;
        LabelIntEnum labelIntEnum = (LabelIntEnum) object;
        if (this.label == null) {
            if (labelIntEnum.label != null)
                return false;
        } else {
            if (!this.label.equals(labelIntEnum.label))
                return false;
        }
        return super.equals(labelIntEnum);
    }

    public int hashCode() {
        int result = super.hashCode();
        result += 29 * result + this.label.hashCode();
        return result;
    }

}
